@layout-header-height: 60px;
@layout-tab-title-height: 37px;
@layout-footer-height: 44px;
@side-left-width: 200px;
@side-shrink-left-width: 60px;
@layout-tabs-title-height: 35px;

.layui-layout-admin {
    .layui-header {
        .layui-logo {
            transition: all .2s;
            .logo-img {
                display: inline-block;
                height: 40px;
                vertical-align: middle;
            }
            .logo-title {
                display: inline-block;
                margin: 0 0 0 12px;
                color: #ffffff;
                font-weight: 600;
                font-size: 20px;
                font-family: Avenir, Helvetica Neue, Arial, Helvetica, sans-serif;
                vertical-align: middle;
            }
        }
        .layui-layout-left {
            .layui-side-flexible {
                a {
                    padding: 0;
                    padding-right: 20px;
                }
                i {
                    &::before {
                        content: "\e668";
                    }
                }
            }
            .layui-nav-bar {
                display: none;
            }
            .menu-icon {
                margin-right: 5px;
            }
        }
        .layui-layout-right {
            padding: 0;
            .layui-nav-language {
                .layui-nav-more {
                    display: none;
                }
            }
            .layui-system-setting {
                a {
                    padding: 0 10px;
                }
            }
        }
    }
    .layui-side {
        .layui-user-area {
            display: none;
        }
        transition: all .2s;
        ul {
            transition: all .2s;
        }
        .menu-icon {
            margin-right: 5px;
        }
    }
    .layui-body {
        >.layui-tab {
            margin: 0;
            .layui-tab-title {
                padding-left: 35px;
                padding-right: 80px;
                height: @layout-tabs-title-height;
                border: 1px solid whitesmoke;
                background-color: white;
                li {
                    height: @layout-tabs-title-height;
                    line-height: @layout-tabs-title-height;
                    &:hover {
                        background-color: #f6f6f6;
                    }
                    span {
                        color: #acafb1;
                    }
                    .tab-pre-icon {
                        display: inline-block;
                        background-color: lightgray;
                        width: 9px;
                        height: 9px;
                        border-radius: 30px;
                        margin-right: 5px;
                    }
                }
                .layui-this {
                    &:after {
                        height: @layout-tabs-title-height;
                    }
                    span {
                        color: dimgray;
                    }
                }
                .layui-tab-close {
                    font-size: 12px;
                    width: 14px;
                    height: 14px;
                    line-height: 16px;
                    border-radius: 100%;
                }
                .disable-close {
                    +.layui-tab-close {
                        display: none;
                    }
                }
                .layui-tab-bar {
                    display: none;
                }
            }
            .layui-tab-control {
                >li {
                    position: absolute;
                    top: 0px;
                    height: @layout-tabs-title-height;
                    line-height: @layout-tabs-title-height;
                    width: 35px;
                    text-align: center;
                    color: #666;
                    background-color: white;
                    border-top: whitesmoke 1px solid;
                    border-bottom: whitesmoke 1px solid;
                    border-left: 1px solid whitesmoke;
                    cursor: pointer;
                    &:hover {
                        background-color: #f6f6f6;
                    }
                }
                .tab-roll-left {
                    left: 0px;
                    border-right: whitesmoke 1px solid;
                    border-left: whitesmoke 1px solid;
                }
                .tab-roll-right {
                    right: 70px;
                }
                .tab-page-close {
                    right: 35px;
                    >.layui-nav {
                        position: absolute;
                        top: 0;
                        width: 100%;
                        height: 100%;
                        padding: 0;
                        background: 0 0;
                        .layui-nav-item {
                            height: @layout-tabs-title-height;
                            background-color: transparent;
                        }
                        .layui-nav-child {
                            left: auto;
                            top: 37px;
                            right: 3px;
                            width: 120px;
                            border: 1px solid whitesmoke;
                        }
                        .layui-nav-bar {
                            display: none;
                        }
                    }
                }
                .tab-page-refresh {
                    right: 0;
                }
            }
            .layui-tab-content {
                position: fixed;
                top: @layout-header-height+@layout-tab-title-height;
                left: @side-left-width;
                right: 0;
                bottom: @layout-footer-height;
                .layui-tab-item {
                    position: absolute;
                    top: 0;
                    bottom: 0;
                    left: 0;
                    right: 0;
                    overflow: hidden;
                    .multi-tab-iframe {
                        position: absolute;
                        width: 100%;
                        height: 100%;
                        border: none;
                        left: 0;
                        top: 0;
                        right: 0;
                        bottom: 0;
                    }
                }
            }
        }
    }
    .layui-footer {
        background-color: white;
    }
    // 收缩模式
    &.layui-side-shrink {
        .layui-header {
            .layui-logo {
                width: @side-shrink-left-width;
                .logo-title {
                    display: none;
                }
            }
            .layui-layout-left {
                left: @side-shrink-left-width;
                .layui-side-flexible {
                    i {
                        &::before {
                            content: "\e66b";
                        }
                    }
                }
            }
        }
        .layui-side {
            left: 0;
            width: @side-shrink-left-width;
            ul, 
            ul li {
                width: @side-shrink-left-width;
            }
            .layui-user-area {
                padding: 0 !important;
                .side-user-pic {
                    .layui-nav-img {
                        width: 30px !important;
                        height: 30px !important;
                    }
                }
                .side-user-text {
                    display: none;
                }
                .layui-nav-dropdown {
                    min-width: unset !important;
                    width: @side-shrink-left-width !important;
                    left: 0 !important;
                    span {
                        display: none;
                    }
                }
            }
            .layui-nav {
                position: static; 
                width: @side-shrink-left-width;
                .layui-nav-item {
                    position: static; 
                }
                a {
                    cite,
                    .layui-nav-more {
                        display: none; 
                    }
                }
                .layui-nav-hover {
                    border-radius: 4px;
                    overflow: hidden;
                    background-color:#28333E;
                    display: block;
                    position: fixed;
                    min-width: 130px;
                    margin-left: 62px;
                    padding-top: 4px!important;
                    padding-bottom: 4px!important;
                    box-shadow: 0px  0px 3px lightgray;
                    cite,
                    .layui-nav-more {
                        display: inline-block!important;
                    }
                }
            }
        }
        .layui-body {
            left: @side-shrink-left-width;
            >.layui-tab {
                .layui-tab-content {
                    left: @side-shrink-left-width;
                }
            }
        }
        .layui-footer {
            left: @side-shrink-left-width;
        }
    }
    &.layout-header-hidden {
        >.layui-header {
            display: none;
        }
        >.layui-side,
        >.layui-body {
            top: 0;
            >.layui-tab {
                .layui-tab-content {
                    top: @layout-tab-title-height;
                }
            }
        }
        >.layui-side {
            .layui-user-area {
                display: block;
                height: 60px;
                padding: 10px 0;
                clear: both;
                >.layui-nav {
                    .layui-nav-item {
                        >a {
                            padding: 0;
                            padding-right: 14px;
                            clear: both;
                            .side-user-pic {
                                float: left;
                                .layui-nav-img {
                                    width: 50px;
                                    height: 50px;
                                }
                            }
                            .side-user-text {
                                float: left;
                                margin: 5px;
                                line-height: 22px;
                                color: white;
                                .desc {
                                    position: fixed;
                                    font-size: 12px;
                                    color: #dcdcdc;
                                }
                            }
                            .layui-nav-more {
                                top: 25%;
                            }
                        }
                    }
                    .layui-nav-bar {
                        display: none;
                    }
                }
            }
        }
    }
    &.layout-footer-hidden {
        >.layui-body {
            bottom: 0;
            >.layui-tab {
                .layui-tab-content {
                    bottom: 0;
                }
            }
        }
        >.layui-footer {
            display: none;
        }
    }
    // 公共样式
    .layui-nav-dropdown {
        .layui-this {
            background-color: #f2f2f2 !important;
            a {
                color: #333 !important;
                background-color: #f2f2f2 !important;
                &:hover {
                    background-color: #f2f2f2 !important;
                }
            }
        }
    }
}